# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=asteroid-flashlight
pkgver=0_git20210517
pkgrel=0
_commit="967f5c0ef9d312b369138f24beae2c8ae30b0c06"
pkgdesc="Default flashlight app for AsteroidOS"
url="https://github.com/AsteroidOS/asteroid-flashlight"
# armhf blocked by qml-asteroid
arch="all !armhf"
license="GPL-3.0-or-later"
depends="
	mapplauncherd
	nemo-keepalive
	"
makedepends="
	extra-cmake-modules
	qml-asteroid-dev
	qt5-qtbase-dev
	qt5-qtdeclarative-dev
	"
source="https://github.com/AsteroidOS/asteroid-flashlight/archive/$_commit/asteroid-flashlight-$_commit.tar.gz"
options="!check" # No tests
builddir="$srcdir/$pkgname-$_commit"

build() {
	cmake -B build \
		-DCMAKE_BUILD_TYPE=None \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib
	cmake --build build
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
1a3da1e9b4e2c28f3febc48f2b93bc83a1dfddf3e347c08849e5308591d638b9d92009824f648b526ec492bc2cc6e6d4d64ac353e28be2e569640f59bd5eb948  asteroid-flashlight-967f5c0ef9d312b369138f24beae2c8ae30b0c06.tar.gz
"
